package com.wqm.step.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.wqm.step.dao.HQLDao;
import com.wqm.step.dao.LoadDao;
import com.wqm.step.pojo.Customer;
import com.wqm.step.pojo.Order;
import com.wqm.step.service.HibernateService;

@Service
public class HibernateServiceImpl implements HibernateService{

	@Autowired
	private HQLDao hqlDao;
	
	@Autowired
	private LoadDao loadDao;
	
	/**
	 * 向一对多数据表中添加10条数据
	 */
	public void saveDataInDatabase(Customer c) {
		hqlDao.saveDataInDatabase(c);
	}

	public List<Customer> findAllCustomer() {
		return hqlDao.findAllCustomer();
	}

	public List<Order> findOrderSort() {
		return hqlDao.findOrderSort();
	}

	public List<Order> findCondition() {
		return hqlDao.findCondition();
	}

	public List<Order> findPage() {
		return hqlDao.findPage();
	}

	public List<Order> findGroup() {
		return hqlDao.findGroup();
	}

	public List<Customer> findColumnData() {
		return hqlDao.findColumnData();
	}

	public Customer findLoad() {
		return loadDao.findLoad();
	}

}
